package com.lzy.pattern.decorator;

/**
 * @ClassName: Bacon
 * @Description: 具体装饰类
 * @Author: LiuZy
 * @Date: 2022/4/23 14:52
 * @Version: 1.0
 */
public class Bacon extends Garnish{


    public Bacon(FastFood fastFood, double price, String desc) {
        super(fastFood, price, desc);
    }

    @Override
    public double cost() {
        return super.getPrice() + super.getFastFood().cost();
    }

    @Override
    public String getDesc() {
        return super.getDesc() + super.getFastFood().getDesc();
    }
}